dofile ("libNumericUpDown.lua")

n1 = NumericUpDown.new(SCREEN_DOWN, 5, 5, 50, 15, 50, 0, 100, 1)
n2 = NumericUpDown.new(SCREEN_DOWN, 5, 52, 100, 30, 100, 0, 200, 2)

while not Keys.held.Start do
	
	Controls.read()
	
	val1, maxVal1, minVal1, step1 = n1:getValue(), n1:getMaxValue(), n1:getMinValue(), n1:getStep()
	val2, maxVal2, minVal2, step2 = n2:getValue(), n2:getMaxValue(), n2:getMinValue(), n2:getStep()
	
	startDrawing()
		
		n1:draw()
		n2:draw()
		
		screen.print (SCREEN_UP, 5, 5, "NumericUpDown 1 : "..minVal1.." < "..val1.." > "..maxVal1.." by "..step1.."")
		screen.print (SCREEN_UP, 5, 15, "NumericUpDown 2 : "..minVal2.." < "..val2.." > "..maxVal2.." by "..step2.."")
		
	stopDrawing()
	
end

n1:clear()
n2:clear()
